difference because the default policy is the "NULL" policy, which as the name
implies does not enforce anything.
-However, when you try
-
-[root@laptop policy]# xm list
-Name Id Mem(MB) CPU State Time(s) Console SSID-REF
-Domain-0 0 620 0 r---- 25.6 default
-
-You might detect a new parameter "SSID-REF" displayed for domains. This
-parameter describes the subject security identifier reference of the domain. It
-is shown as "default" since there is no policy to be enforced.
-
To display the currently enforced policy, use the policy tool under xeno-
unstable.bk/tools/policy: policy_tool getpolicy. You should see output like the
one below.
Then
[root@laptop policy]# xm list
-Name Id Mem(MB) CPU State Time(s) Console SSID-REF
+Name Id Mem(MB) CPU State Time(s) Console
Domain-0 0 620 0 r---- 42.3 s:00/p:00
xmnosec 1 9 0 -b--- 0.3 9601 s:00/p:05
xmsec1 2 9 0 -b--- 0.2 9602 s:01/p:01
.
.
[root@laptop policy]# xm list
-Name Id Mem(MB) CPU State Time(s) Console SSID-REF
+Name Id Mem(MB) CPU State Time(s) Console
Domain-0 0 620 0 r---- 71.7 s:00/p:00
xmsec1 1 9 0 -b--- 0.3 9601 s:01/p:01
xmsec2 2 7 0 -b--- 0.3 9602 s:02/p:02 << our domain runs both policies with ssidref 2
Our policy interface enables managers to create a single binary policy file in a trusted
environment and distributed it to multiple systems for enforcement.
-====================end-of file=======================================
\ No newline at end of file
+====================end-of file=======================================
self.brief_list(doms)
def brief_list(self, doms):
- print 'Name Id Mem(MB) CPU VCPU(s) State Time(s) Console SSID-REF'
+ print 'Name Id Mem(MB) CPU VCPU(s) State Time(s) Console'
for dom in doms:
info = server.xend_domain(dom)
d = {}
d['ssidref2'] = (int(sxp.child_value(info, 'ssidref', '-1')) >> 16) & 0xffff
print ("%(name)-16s %(dom)3d %(mem)7d %(cpu)3d %(vcpus)5d %(state)5s %(cpu_time)7.1f %(port)4s s:%(ssidref2)02x/p:%(ssidref1)02x" % d)
else:
- print ("%(name)-16s %(dom)3d %(mem)7d %(cpu)3d %(vcpus)5d %(state)5s %(cpu_time)7.1f %(port)4s default" % d)
+ print ("%(name)-16s %(dom)3d %(mem)7d %(cpu)3d %(vcpus)5d %(state)5s %(cpu_time)7.1f %(port)4s" % d)
def show_vcpus(self, doms):
print 'Name Id VCPU CPU CPUMAP'